using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._TerritoryDesignTools._TerritorySolution
{
    /// <summary>
    /// <para>Generate Territory Report</para>
    /// <para>Creates a summary report of a territory solution or a comparison report of two solutions.</para>
    /// <para>创建区域解决方案的摘要报告或两个解决方案的比较报告。</para>
    /// </summary>    
    [DisplayName("Generate Territory Report")]
    public class GenerateTerritoryReport : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public GenerateTerritoryReport()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_territory_solution">
        /// <para>Input Territory Solution</para>
        /// <para>The input territory solution for the report.</para>
        /// <para>报表的输入区域解决方案。</para>
        /// </param>
        /// <param name="_level">
        /// <para>Level</para>
        /// <para>The territory level to create the report.</para>
        /// <para>用于创建报表的区域级别。</para>
        /// </param>
        public GenerateTerritoryReport(object _in_territory_solution, object _level)
        {
            this._in_territory_solution = _in_territory_solution;
            this._level = _level;
        }
        public override string ToolboxName => "Territory Design Tools";

        public override string ToolName => "Generate Territory Report";

        public override string CallName => "td.GenerateTerritoryReport";

        public override List<string> AcceptEnvironments => ["workspace"];

        public override object[] ParameterInfo => [_in_territory_solution, _level, _report_type.GetGPValue(), _report_folder, _report_title, _report_format, _comparison_territory_solution, _comparison_level, _output_report];

        /// <summary>
        /// <para>Input Territory Solution</para>
        /// <para>The input territory solution for the report.</para>
        /// <para>报表的输入区域解决方案。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Territory Solution")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_territory_solution { get; set; }


        /// <summary>
        /// <para>Level</para>
        /// <para>The territory level to create the report.</para>
        /// <para>用于创建报表的区域级别。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Level")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _level { get; set; }


        /// <summary>
        /// <para>Report Type</para>
        /// <para><xdoc>
        ///   <para>Specifies the type of report that will be generated.</para>
        ///   <bulletList>
        ///     <bullet_item>Territory Summary—The report contains a summary of a territory solution, such as hierarchy and statistics. This is the default.</bullet_item><para/>
        ///     <bullet_item>Compare Territories—The report compares two territory solutions.</bullet_item><para/>
        ///     <bullet_item>Realignment— The report contains a summary realignment report for the territories.</bullet_item><para/>
        ///     <bullet_item>Realignment Detailed— The report contains a full list of the reassigned features.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将生成的报告类型。</para>
        ///   <bulletList>
        ///     <bullet_item>区域摘要 - 报告包含区域解决方案的摘要，例如层次结构和统计数据。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>比较区域 - 报告比较两个区域解决方案。</bullet_item><para/>
        ///     <bullet_item>重新调整 - 报告包含区域的摘要重新调整报告。</bullet_item><para/>
        ///     <bullet_item>重新对齐详细信息 - 报告包含重新分配要素的完整列表。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Report Type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _report_type_value? _report_type { get; set; } = null;

        public enum _report_type_value
        {
            /// <summary>
            /// <para>Territory Summary</para>
            /// <para>Territory Summary—The report contains a summary of a territory solution, such as hierarchy and statistics. This is the default.</para>
            /// <para>区域摘要 - 报告包含区域解决方案的摘要，例如层次结构和统计数据。这是默认设置。</para>
            /// </summary>
            [Description("Territory Summary")]
            [GPEnumValue("TERRITORY_SUMMARY")]
            _TERRITORY_SUMMARY,

            /// <summary>
            /// <para>Compare Territories</para>
            /// <para>Compare Territories—The report compares two territory solutions.</para>
            /// <para>比较区域 - 报告比较两个区域解决方案。</para>
            /// </summary>
            [Description("Compare Territories")]
            [GPEnumValue("COMPARE_TERRITORIES")]
            _COMPARE_TERRITORIES,

            /// <summary>
            /// <para>Realignment</para>
            /// <para>Realignment— The report contains a summary realignment report for the territories.</para>
            /// <para>重新调整 - 报告包含区域的摘要重新调整报告。</para>
            /// </summary>
            [Description("Realignment")]
            [GPEnumValue("REALIGNMENT")]
            _REALIGNMENT,

            /// <summary>
            /// <para>Realignment Detailed</para>
            /// <para>Realignment Detailed— The report contains a full list of the reassigned features.</para>
            /// <para>重新对齐详细信息 - 报告包含重新分配要素的完整列表。</para>
            /// </summary>
            [Description("Realignment Detailed")]
            [GPEnumValue("REALIGNMENT_DETAILED")]
            _REALIGNMENT_DETAILED,

        }

        /// <summary>
        /// <para>Output Report Folder</para>
        /// <para>The output location where the report will be saved.</para>
        /// <para>将保存报表的输出位置。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Report Folder")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _report_folder { get; set; } = null;


        /// <summary>
        /// <para>Report Title</para>
        /// <para>The title of the report.</para>
        /// <para>报表的标题。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Report Title")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _report_title { get; set; } = null;


        /// <summary>
        /// <para>Report Output Formats</para>
        /// <para>The report output format. The default value is PDF. Additional available formats: XLSX, HTML, CSV, PAGX.</para>
        /// <para>报表输出格式。默认值为 PDF。其他可用格式：XLSX、HTML、CSV、PAGX。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Report Output Formats")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _report_format { get; set; } = null;


        /// <summary>
        /// <para>Comparison Territory Solution</para>
        /// <para>The territory solution for the comparison report.</para>
        /// <para>比较报告的区域解决方案。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Comparison Territory Solution")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _comparison_territory_solution { get; set; } = null;


        /// <summary>
        /// <para>Comparison Level</para>
        /// <para>The territory level to be used for the comparison or realignment report.</para>
        /// <para>用于比较或重新调整报告的区域级别。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Comparison Level")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _comparison_level { get; set; } = null;


        /// <summary>
        /// <para>Output Report</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Report")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public List<object> _output_report { get; set; }


        public GenerateTerritoryReport SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}